function getPurchaseDetailPage (params) {
  return $axios({
    url: '/purchaseDetail/page',
    method: 'get',
    params
  })
}

// 修改---启用禁用接口
function enableOrDisablePurchaseDetail (params) {
  return $axios({
    url: '/purchaseDetail',
    method: 'put',
    data: { ...params }
  })
}

// 新增---添加员工
function addPurchaseDetail (params) {
  return $axios({
    url: '/purchaseDetail',
    method: 'post',
    data: { ...params }
  })
}

// 修改---添加员工
function editPurchaseDetail (params) {
  return $axios({
    url: '/purchaseDetail',
    method: 'put',
    data: { ...params }
  })
}

// 修改页面反查详情接口
// function queryPurchaseDetailById (id) {
//   return $axios({
//     url: `/purchaseDetail/${id}`,
//     method: 'get'
//   })
// }

// 修改页面反查详情接口
function deletePurchaseDetail (id) {
  return $axios({
    url: `/purchaseDetail/${id}`,
    method: 'delete'
  })
}

function queryPurchaseDetailById (id) {
  return $axios({
    url: `/purchaseDetail/${id}`,
    method: 'get'
  })
}

function getPurchaseDetailListByPurchaseId (purchaseId) {
  return $axios({
    url: `/purchaseDetail/list/${purchaseId}`,
    method: 'get'
  })
}